#ifndef HANDTRACKER_LKGREYwMSwBPwFOx_HPP
#define HANDTRACKER_LKGREYwMSwBPwFOx_HPP

#include <cv.h>
#include <highgui.h>

#include "AbstractHandTracker.hpp"
#include "abstractProbabilityTransformer.hpp"
#include "abstractFilter.hpp"

//LEGEND:
//LKGREY : tracking uses pyrLK on greyscale image
//MS: tracking is then updated with meanshift
	//BP: which uses backprojection
		//FOx: which uses and OpenFilter which iterates x times (x is variable)

class HandTrackerLKGREYwMSwBPwFOx : AbstractHandTracker {
public:
	static AbstractHandTracker* init( cv::Ptr< AbstractProbabilityTransformer > probTrans,
				cv::Rect trackingRect, cv::Mat& initImage, cv::Ptr< AbstractFilter > filter );

	cv::Rect track(cv::Mat& nextImage );
	
protected:
	cv::Ptr< AbstractProbabilityTransformer > probTrans;
	cv::Rect trackingRect;
	cv::Mat imgA;
	cv::Mat imgB;
	
	cv::Mat imgHSV;
	
private:
	
	HandTrackerLKGREYwMSwBPwFOx( cv::Ptr< AbstractProbabilityTransformer > probTrans,
					  cv::Rect trackingRect, cv::Ptr< AbstractFilter > filter );
	
	cv::Mat* imgPtr1;
	cv::Mat* imgPtr2;

	cv::Ptr< AbstractFilter > filter;

};

#endif
	
	
	